//
//  CYCollectItem.m
//  CreditAddressBook
//
//  Created by Mr_Chen on 15/8/29.
//  Copyright (c) 2015年 Lee. All rights reserved.
//

#import "CYCollectItem.h"

@implementation CYCollectItem

- (void)encodeWithCoder:(NSCoder *)encoder
{
    [encoder encodeObject:_phone forKey:@"_phone"];
    [encoder encodeObject:_name forKey:@"_name"];
    [encoder encodeObject:_thumbnailLocal forKey:@"_thumbnailLocal"];
    [encoder encodeObject:_headImageName forKey:@"_headImageName"];
    [encoder encodeInteger:self.recordID forKey:@"self.recordID"];
//    [encoder encodeObject:_indexPath forKey:@"_indexPath"];
//    [encoder encodeObject:_times forKey:@"_times"];
//    [encoder encodeObject:_thumbnailLocal forKey:@"_thumbnailLocal"];
}
- (instancetype)initWithCoder:(NSCoder *)decoder
{
    if (self = [super init]) {
        self.phone = [decoder decodeObjectForKey:@"_phone"];
        self.name = [decoder decodeObjectForKey:@"_name"];
        self.thumbnailLocal= [decoder decodeObjectForKey:@"_thumbnailLocal"];
        self.headImageName = [decoder decodeObjectForKey:@"_headImageName"];
        self.recordID = [decoder decodeIntegerForKey:@"self.recordID"];
//        self.indexPath = [decoder decodeObjectForKey:@"_indexPath"];
//        self.times = [decoder decodeObjectForKey:@"_times"];
//        self.thumbnailLocal = [decoder decodeObjectForKey:@"_thumbnailLocal"];
    }
    return self;
}
@end
